package spelet;

import java.applet.AudioClip;
import javax.swing.*;
import java.net.URL;


public class SoundList extends java.util.Hashtable
{
	JApplet applet;
	URL baseURL;



	public SoundList(URL baseURL)
	{
		super(4); // Initialize Hashtable with capacity of 4 entries


		this.baseURL = baseURL;
	}

	public void startLoading(String relativeURL)
	{
		new SoundLoader(this, baseURL, relativeURL);
	}

	public AudioClip getClip(String relativeURL)
	{
		return (AudioClip)get(relativeURL);
	}

	public void putClip(AudioClip clip, String relativeURL)
	{
		put(relativeURL, clip);
	}
}